﻿@{
    ViewBag.Title = "PayPalTest";
    //Layout = "";
}

@section HeaderScripts {
    <script src="http://code.jquery.com/jquery-latest.min.js"></script>
    <script type="text/javascript" src="~/scripts/smartparking500.js"></script>
    <link rel="stylesheet" type="text/css" href="~/content/jPayPalCart.css" />  
    <script type="text/javascript" src="~/scripts/jPayPalCart8.js"></script>

    <script type='text/javascript'>
        $(document).ready(function () {
            // Create a basic cart
            $("#myPayPalCart").PayPalCart({
                business: 'paypal_1353538362_biz@adevso.net',
                notifyURL: 'http://www.yournotifyURL.com/notify.php',
                virtual: true,             //set to true where you are selling virtual items such as downloads
                quantityupdate: false,       //set to false if you want to disable quantity updates in the cart 
                currency: 'USD',            //set to your trading currency - see PayPal for valid options
                currencysign: '$',          //set the currency symbol
                minicartid: 'minicart',     //element to show the number of items and net value
                persitdays: 0,              //set to -1 for cookie-less cart for single page of products, 
                                            // 0 (default) persits for the session, 
                                            // x (number of days) the basket will persits between visits
                //showCart: false,
                language: 'es'//,
                //returnURL: "@Url.Action("Index")"
            });

            $(document).on("click", "#cmdAddPayPal", null, function () {
                AddPayPal();
            });
        });        
    </script>
}

<h2>PayPal Test</h2>

<div>
    <div data-role="fieldcontain">
        <label for="tboxCode">Code</label>
        <input id="tboxCode" type="text" value="Code1"/>
        <label for="tboxDescription">Description</label>
        <input id="tboxDescription" type="text" value="Description1"/>
    </div>
    <div data-role="fieldcontain">
        <label for="tboxQty">Qty</label>
        <input id="tboxQty" type="number" value="1"/>
        <label for="tboxValue">Value</label>
        <input id="tboxValue" type="number" value="100"/>
    </div>
    <div data-role="fieldcontain">
        <label for="tboxTax">Tax</label>
        <input id="tboxTax" type="number" value="10"/>
    </div>
    <div data-role="fieldcontain">
        <input type="submit" value="Add to PayPal" id="cmdAddPayPal"/>
    </div>
</div>

<div id="myPayPalCart"></div>